{{ if .Path }}
{{ $gh_repo := ($.Param "github_repo") }}
{{ if $gh_repo }}
<div class="td-page-meta ml-2 pb-1 pt-2 mb-0">
{{ $editURL := printf "%s/edit/main/docs-v2/content/%s/%s" $gh_repo ($.Site.Language.Lang) .Path }}
{{ $issuesURL := printf "%s/issues/new?title=%s" $gh_repo (htmlEscape $.Title )}}
<a href="{{ $editURL }}" target="_blank"><i class="fa fa-edit fa-fw"></i> {{ T "post_edit_this" }}</a>
<a href="{{ $issuesURL }}" target="_blank"><i class="fab fa-github fa-fw"></i> {{ T "post_create_issue" }}</a>
{{ if in .Permalink "/docs/references/yaml"}}
    <br>
    <div>Schema Versions</div>
    <select id="schema_links" onchange="selectSchema(this)">
    </select>
    <ul id="schema_list" hidden>
    {{ range (readDir "/content/en/schemas") }}
        {{ if strings.HasSuffix .Name ".json"}}
        <li>{{ trim .Name ".json" }}</li>
        {{ end }}
    {{ end }}
    </ul>

    <script src="../../../javascripts/schemas.js"></script>
{{ end }}
</div>
{{ end }}
{{ end }}
